<?php

class Page {

    function __construct() {
        
    }

    public function GetPage() {
        echo $this->getTop();
        echo $this->getMeta();
        echo $this->getJS();
        echo $this->getCss();
        echo $this->getBottom();
    }

    private function getTop() {
        $top = "<html xmlns='http://www.w3.org/1999/xhtml' lang='en' ><head>";
        return $top;
    }

    private function getMeta() {
        $meta = "<title>Generator 2.0</title>";
        $meta .= "<meta http-equiv='X-UA-Compatible' content='IE=edge' />";
        return $meta;
    }

    private function getJS() {
        $js="";
        $js .= $this->getJsFile("framework/js/jquery.min.js");
        $js .= $this->getJsFile("framework/js/jquery-ui-1.8.21.custom.min.js");
        $js .= $this->getJsFile("framework/js/jquery.form.js");
        $js .= $this->getJsFile("framework/js/jquery.url.js");   //https://github.com/allmarkedup/jQuery-URL-Parser
        $js .= $this->getJsFile("framework/js/jquery.hashchange.js");
        $js .= $this->getJsFile("framework/js/jquery.stringify.js");
        
        //Custom Scroll
        $js .= $this->getJsFile("framework/js/jquery.mousewheel.js");
        $js .= $this->getJsFile("framework/js/jquery.jscrollpane.js");
        
        $js .= $this->getJsFile("framework/controller.js"); // MAIN PART FOR FRAMEWORK
        return $js;
    }

    private function getCss() {
        $css="";
        $css .= $this->getCssFile("css/styles.css");
        $css .= $this->getCssFile("framework/css/googleButtons.css");
        $css .= $this->getCssFile("framework/css/jquery.jscrollpane.css");
        return $css;
    }

    private function getBottom() {
        $bottom = "</head>
                    <body>
                        <div class='static'>
                          <h1 class='mainHeader Grey'>Code Generator</h1>
                        </div>
                        <div class='dynamic'>
                        
                        </div>
                        <div class='footer'></div>
                        <div id='log'></div>
                    </body>
                    </html>";
        return $bottom;
    }
    private function getCssFile($src){
        return "<link href='$src' rel='stylesheet' type='text/css'>";
    }
    private function getJsFile($src) {
        return "<script type='text/javascript' src='$src'></script>";
    }

}

?>